<!DOCTYPE html>
<html lang="zh-cn">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>{$article['title']}</title>
    <link rel="stylesheet" type="text/css" href="/dist/css/bootstrap.min.css"/>
    <link rel="stylesheet" type="text/css" href="/static/css/style.css"/>
    <script src="/dist/lib/jquery-3.1.0.min.js" type="text/javascript" charset="utf-8"></script>
    <script src="/dist/js/bootstrap.min.js" type="text/javascript" charset="utf-8"></script>
    <script src="/static/js/script.js" type="text/javascript" charset="utf-8"></script>
</head>

<body id="web-top">
<!--导航栏-->
<nav class="navbar navbar-inverse" style="border-radius: 0px;">
    <div class="container">
        <div class="row">
            <div class="navbar-header">
                <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#zero-navbar">
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                </button>
                <a class="navbar-brand" href="/">零度文摘</a>
            </div>
            <div class="collapse navbar-collapse" id="zero-navbar">
                <ul class="nav navbar-nav">
                    <li>
                        <a href="/">首页</a>
                    </li>
                    {$article['belong']==1 ? "
                    <li class='active'>" : "
                    <li>"}
                        <a href="/guokr">果壳</a>
                    </li>
                    {$article['belong']==2 ? "
                    <li class='active'>" : "
                    <li>"}
                        <a href="/zhihu">知乎</a>
                    </li>
                    {$article['belong']==3 ? "
                    <li class='active'>" : "
                    <li>"}
                        <a href="/douban">豆瓣</a>
                    </li>
                </ul>
            </div>
        </div>
    </div>
</nav>
<div class="container">
    <div class="row">
        <div class="col-md-8 col-sm-8">
            <div class="article">
                <div class="article-head">
                    <h1>{$article['title']}</h1>
                    <hr/>
                    <div class="row">
                        <div class="col-md-12 col-md-offset-0">
                            <blockquote>
                                <p>{$article['abstract']}</p>
                                <footer>{$article['author']}<cite class="pull-right">{$article['date']}</cite></footer>
                            </blockquote>
                        </div>
                    </div>
                    <div class="row">
                        <div class="col-md-10 col-md-offset-1">
                            <img class="img-responsive" src="{$article['image']}"/>
                        </div>
                    </div>
                </div>
                <div class="article-body">
                    {$article['content']}
                </div>
            </div>
            <div class="row article-commend">
                <div class="page-header">
                    <h3 style="padding-left: 10px;">相关推荐&nbsp;
                        <small>RELATED ARTICLE</small>
                    </h3>
                </div>
                {for start="0" end="4"}
                <div class="col-md-3 col-sm-6">
                    <a href="#">
                        <div class="thumbnail">
                            <img class="img-responsive hidden-xs" src="{$article['image']}"/>
                            <div class="caption">
                                <h3>{$article['title']}</h3>
                                <p class="visible-xs">{$article['abstract']}</p>
                            </div>
                        </div>
                    </a>
                </div>
                {/for}
            </div>
        </div>
        <div class="col-md-4 col-sm-4 hidden-xs">
            <div class="page-header" style="text-align: center;margin: 0px;">
                <h3 style="margin: 10px 0px 4px 0px;">文章排行</h3>
                <small style="color: #777;;">TOP ARTICLES</small>
            </div>
            <ol class="article-ranking">
                {for start="0" end="3"}
                <li>
                    <a href="#">{$article['title']}</a>
                    <p class="hidden-sm">
                        {php}
                        if (mb_strlen($article['abstract']) > 64) {
                        echo mb_substr($article['abstract'], 0, 64) . '...';
                        } else {
                        echo $article['abstract'];
                        }
                        {/php}
                    </p>
                </li>
                {/for}
                {for start="3" end="7"}
                <li>
                    <a href="#">{$article['title']}</a>
                </li>
                {/for}
            </ol>
            <a href="#web-top" class="btn btn-default hidden-xs" id="return-top">
                <i class="glyphicon glyphicon-arrow-up"></i>&nbsp;返回顶部
            </a>
        </div>
    </div>
</div>
</body>

</html>